package com.hex.ds.hdrs.label.dao;

import com.hex.bigdata.hbda.base.BaseDao;
import com.hex.ds.hdrs.label.po.LabelJobPo;
import org.springframework.stereotype.Repository;

import java.util.List;
import java.util.Map;

@Repository
public class LabelJobDao extends BaseDao {

    public Integer insert(LabelJobPo labelJobPo) {
       return this.insert("com.hex.ds.hdrs.label.dao.LabelJobDao.insert", labelJobPo);
    }

    public void delete(LabelJobPo labelJobPo) {
        this.delete("com.hex.ds.hdrs.label.dao.LabelJobDao.delete", labelJobPo);
    }

    public void deleteByJobCode(String jobCode) {
        this.delete("com.hex.ds.hdrs.label.dao.LabelJobDao.deleteByJobCode", jobCode);
    }

    public List<LabelJobPo> queryList(LabelJobPo labelJobPo) {
        return this.selectList(LabelJobPo.class, "com.hex.ds.hdrs.label.dao.LabelJobDao.query", labelJobPo);
    }

    public List<String> queryLabelByJobCode(String jobCode) {
        return this.selectList(String.class, "com.hex.ds.hdrs.label.dao.LabelJobDao.queryLabelByJobCode", jobCode);
    }

    public List<String> qryJobCodeByLabelName(String labelName) {
        return this.selectList(String.class, "com.hex.ds.hdrs.label.dao.LabelJobDao.qryJobCodeByLabelName", labelName);
    }

    public List<String> qryLabelIsInUser(String pkId) {
        return this.selectList(String.class, "com.hex.ds.hdrs.label.dao.LabelJobDao.qryLabelIsInUser", pkId);
    }
}
